package com.matt.docpro.service;

import com.matt.docpro.mapper.BlogMapper;
import com.matt.docpro.mapper.CheckinMapper;
import com.matt.docpro.model.Blog;
import com.matt.docpro.model.Checkin;
import com.matt.docpro.model.Clinic;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * AppointmentService
 * Created by on 2024/02/20.
 */
@Service
public class BlogService {

    @Autowired
    BlogMapper blogMapper;

    public List<Blog> getAll() {
        return blogMapper.getAll();
    }

    public Blog getById(String id) {
        return blogMapper.getById(id);
    }

    public void update(Blog blog) {
        blogMapper.update(blog);
    }

    public void insert(Blog blog) {
        blogMapper.insert(blog);
    }

    public void delete(String id) {
        blogMapper.deleteById(id);
    }
}
